import { buffer } from "node_polyfill";

const log = (message) => {
    console.log(message)
}

export function run_buffer (){
    const str = "这是一段文本...";
    log("------ buffer demo start ------")
    const base64Str = buffer.Buffer.from(str).toString("base64");
    log("str to base64结果：" + base64Str);
    log("------ buffer demo end ------")
}